<style>
<!--
#content{
	background: none;
	padding : 0;
}
-->
</style>
<?php foreach ($this->entries as $entry):?>
<div class="article" id="<?php echo $this->escape($entry->id)?>">
	<div class="title"><?php echo $this->escape(utf8_encode($entry->title))?></div>
	<div class="message"><?php echo $this->escape(utf8_encode($entry->text)) ?></div>
	<div class="links"><div class="user"><?php echo ucfirst($this->escape($entry->prenom)).' '.ucfirst($this->escape($entry->nom)).' - '.$this->escape($entry->date).' - <a href="#" class="bt_com">View comments</a>'?></div></div>
	<div class="comments">
		<div class="viewCom" id="<?php echo $this->baseUrl().'/comment/index/news/';?>"></div>
		<div class="addCom" id="<?php echo $this->baseUrl().'/comment/add/';?>">
			<div class="form-errors"></div>
			<?php 
			if($this->form){
				$this->form->getElement('news')->setValue($entry->id);
				echo $this->form;
			}else{
				echo 'Please <a href="'.$this->url(array('controller'=>'login','action'=>'index')).'">log-in</a> to post comments !';
			}
			?>
		</div>
	</div>
</div>
<?php endforeach ?>
<?php echo $this->paginationControl($this->entries, 'Elastic', 'pagination_controll.phtml')?>
<?php $this->headScript()->appendFile($this->baseUrl().'/js/news.js');?>